<?php
/*
Single Post Template: Post - Reference Projects
*/
?>

<?php get_header() ?>
<?php include 'single-reference-project-calculations.php' ; ?>

<style>
	#content .refprojectmainimage { width: 300px; border: #cccccc 3px solid; float: right; margin: 0px; margin-left: 20px; margin-bottom: 10px; }
		#content .refprojectmainimage { width: 300px; margin: 0px; border: 0px; }
	#content .refprojecttopbox { width: 313px; padding: 10px; border: #cccccc 1px solid; background-color: #f2f2f2; float: left; margin: 0px; }
		#content .refprojecttopbox h4 { font-family: arial; font-size: 18px; font-weight: bold; line-height: 18px; margin: 0px; margin-bottom: 10px; margin-left: 0px; }
		#content .refprojecttopbox ul { list-style: none; padding: 0px; }
			#content .refprojecttopbox ul li { width: 313px; height: 18px; line-height: 18px; }
				#content .refprojecttopbox ul li span { text-align: right; float: right; clear: right; height: 18px; line-height: 18px; font-weight: bold; }
				
	#content table.rpdatatable th { background-color: #e77d1d; height: 30px; line-height: 30px; color: #ffffff; font-size: 15px; font-weight: bold; text-align: left; padding-left: 10px; }
	#content table.rpdatatable td { height: 30px; line-height: 30px; }
		#content table.rpdatatable td:first-child { text-align: left; padding-left: 10px; }
		#content table.rpdatatable td:second-child { text-align: right; padding-right: 10px; }
		#content table.rpdatatable td span.financeright { float: right; text-align: right; }
	#content table.rpdatatable tr:nth-child(odd) { background-color: #f2f2f2; }
	
	#content .refproject-relatedbox { width: 213px; float: left; margin: 0px; text-align: center; }
		#content .refproject-relatedbox a, #content .refproject-relatedbox a:visited { display: inline-block; width: 203px; padding: 5px; margin: 0px; text-decoration: none; }
			#content .refproject-relatedbox img, #content .refproject-relatedbox a img { width: 197px; height: 197px; border: #cccccc 3px solid; margin-bottom: 10px; }
			#content .refproject-relatedbox a h4 { color: #e77d1d; font-size: 18px; font-weight: bold; line-height: 18px; margin: 0px; margin-bottom: 10px; }
			#content .refproject-relatedbox a p { font-size: 12px; font-weight: normal; line-height: 12px; margin: 0px; margin-bottom: 10px; color: #000000; }
			#content .refproject-relatedbox a p.refproject-button { display: block; height: 30px; line-height: 30px; font-size: 12px; font-weight: bold; color: #ffffff; background-color: #e77d1d; margin-bottom: 0px; }
			#content .refproject-relatedbox:hover { background-color: #f2f2f2; }
				#content .refproject-relatedbox:hover a p.refproject-button { background-color: #002d55; }
				#content .refproject-relatedbox:hover a h4 { color: #002d55; }
				
	#content p a.printbutton, #content a.printbutton:visited { display:block;width:140px;height:30px;line-height:30px;text-align:center;background:#e77d2d;color:#ffffff;font-weight:bold;text-decoration:none; }
		#content p a.printbutton:hover { background:#002d55; }
</style>

	<div id="container">
    
    	<?php include('breadcrumbs.php'); ?>
    
		<div id="content">

<?php the_post() ?>

			<div id="post-<?php the_ID() ?>" class="<?php sandbox_post_class() ?>">
				<h2 class="entry-title"><?php the_title() ?></h2>
                <?php include ('socialbuttons.php'); ?>
                <p><a href="<?php the_permalink(); ?>?output=pdf" target="_blank" class="printbutton">PDF/Print Version</a></p>
				<div class="entry-content rp-content">
                
                
                	<!-- Begin Reference Project Details Box -->
                    
                    <div class="refprojecttopbox">
    	<h4>Project Quick Reference</h4>
        <ul>
        	<li>Customer: <span><?php meta('RPCustomer'); ?></span></li>
            <li>Location: <span><?php meta('RPLocation'); ?></span></li>
            <li>Building Type: <span><?php meta('RPBuildingType'); ?></span></li>
            <li>Solar System Type: <span><?php meta('RPSystemType'); ?></span></li>
            <li>Type Of Solar Collectors: <span><?php meta('RPCollectorType'); ?></span></li>
            <li>Solar Collector Model: <span><?php meta('RPCollectorModel'); ?></span></li>
            <li>Qty Of Solar Collectors: <span><?php meta('RPCollectorQty'); ?></span></li>
            <li>Anticipated Solar Fraction: <span><?php meta('RPSolarFraction'); ?>%</span></li>
            <li>Anticipated 15yr Energy Savings: <span>
            	<?php if(get_post_meta($post->ID, 'RP15YearSavings', true)) { ?>
					$ <?php meta('RP15YearSavings'); ?> ft2
				<?php } else { ?>
					$ <?php echo $echosavings ; ?>
				<?php } ?>
            </span></li>
            <li>Install Completion Date: <span><?php meta('RPDate'); ?></span></li>
        </ul>
    </div>
    <div class="refprojectmainimage">
    	<?php the_post_thumbnail(); ?>
    </div>
    
    <div style="width: 661px; height: 0px; clear: both; margin-bottom: 20px;"></div>

	<h3>Project Overview</h3>
	<?php the_content(); ?>
	    
    <h3>Project Details &amp; Further Information</h3>
    <!-- ROTATOR CONTENT SECTION -->
    <div class="marketbutton">
		<div class="marketbuttonleft"><h2>Building Details</h2></div>
    	<div class="marketbuttonright">+ Open / Close</div>
	</div>
	<div class="marketcontent">
    	<div style="width: 639px; margin-top: 10px; margin-bottom: 10px; margin-left: auto; margin-right: auto;">
			<?php include 'refproject-tab1.php'; ?>
        </div>
	</div>
    
    <div class="marketbutton">
		<div class="marketbuttonleft"><h2>Solar System Details</h2></div>
    	<div class="marketbuttonright">+ Open / Close</div>
	</div>
	<div class="marketcontent">
    	<div style="width: 639px; margin-top: 10px; margin-bottom: 10px; margin-left: auto; margin-right: auto;">
			<?php include 'refproject-tab2.php'; ?>
        </div>
	</div>
    
    <div class="marketbutton">
		<div class="marketbuttonleft"><h2>Financial Details</h2></div>
    	<div class="marketbuttonright">+ Open / Close</div>
	</div>
	<div class="marketcontent">
    	<div style="width: 639px; margin-top: 10px; margin-bottom: 10px; margin-left: auto; margin-right: auto;">
			<?php include 'refproject-tab3.php'; ?>
        </div>
	</div>
    
    <?php // if ( meta($post->ID, 'RPSunWatcherURL', true) ) { ?>
    <!--
    <div class="marketbutton">
		<div class="marketbuttonleft"><h2>Real Time Performance Monitoring</h2></div>
    	<div class="marketbuttonright">+ Open / Close</div>
	</div>
	<div class="marketcontent">
    	<div style="width: 639px; margin-top: 10px; margin-bottom: 10px; margin-left: auto; margin-right: auto;">
			<?php // include 'refproject-tab4.php'; ?>
        </div>
	</div> -->
    <?php // } ?>
    
    <?php if ( get_post_meta($post->ID, 'RPSunMaxxPRLink', true) ) { ?>
    <div class="marketbutton">
		<div class="marketbuttonleft"><h2>Press &amp; Publicity</h2></div>
    	<div class="marketbuttonright">+ Open / Close</div>
	</div>
	<div class="marketcontent">
    	<div style="width: 639px; margin-top: 10px; margin-bottom: 10px; margin-left: auto; margin-right: auto;">
			<?php include 'refproject-tab5.php'; ?>
        </div>
	</div>
    <?php } ?>
    
    <!--
    <div class="marketbutton">
		<div class="marketbuttonleft"><h2>Similar Projects</h2></div>
    	<div class="marketbuttonright">+ Open / Close</div>
	</div>
	<div class="marketcontent">
    	<div style="width: 639px; margin-top: 10px; margin-bottom: 10px; margin-left: auto; margin-right: auto;">
			<?php // include 'refproject-tab6.php'; ?>
        </div>
	</div>-->
    
    <div id="accordian-wrapper" style="margin-bottom: 20px; margin-top: 20px;">

        <!-- Include The Project's Image Gallery -->
		<div class="accbutton-images">
    		<div class="accbutton-images-left">Project Installation Image Gallery</div>
        	<div class="accbutton-images-right">View Images</div>
    	</div> 
		<div class="acccontent-images">
    		<?php include 'refproject-tabgallery.php'; ?>
    	</div>
        
	</div>
                    
                    <!-- INCLUDE END OF PAGE CTA BLOCK IF THE PAGE HAS A CTA URL -->
                    <?php if(get_post_meta($post->ID, "ctaURL", true)){ include('inpagecta.php') ; } ?>
					
                    <?php include 'facebook-comments.php'; ?>
                    
				</div>
			</div><!-- .post -->

		</div><!-- #content -->
        
        <?php get_sidebar() ?>
        <div style="width: 960px; height: 0px; clear: both;"></div>
        
	</div><!-- #container -->

<?php get_footer() ?>